﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
using System.Data.SqlClient;
using System.Text;
using System.Data;

public partial class Default5 : System.Web.UI.Page
{
    public SqlConnection MyConn()
    {
        SqlConnection myConn = new SqlConnection(System.Configuration.ConfigurationManager.ConnectionStrings["AUODB"].ConnectionString);
        return myConn;
    }

    protected void Page_Load(object sender, EventArgs e)
    {

    }
    protected void Button1_Click(object sender, EventArgs e)
    {



        StringBuilder sb = new StringBuilder();

        sb.AppendLine("SELECT * ");
        sb.AppendLine("FROM GroupID ");

        SqlConnection aconn;

        SqlDataReader MyDataReader;
        Int16 ii;
        for (ii = 0; ii < 100; ii++)
        {
            aconn = MyConn();
            MyDataReader = SqlHelper.ExecuteReader(aconn, CommandType.Text, sb.ToString());
            //MyDataReader.Close();
            aconn.Close();

        }


    }
}
